package com.ld.tool.model.tool;

import java.util.List;

import lombok.Data;

/**
 * sql文件model
 * 
 * @author <a href="mailto:donggongai@126.com" target="_blank">吕凯</a>
 * @date 2019年11月6日 上午11:50:58
 *
 */
@Data
public class SqlFileGroupSourceModel {
    private String source; // 来源
    private List<SqlFileModel> files; // 路径

    @Override
    public boolean equals(Object o) {
        if (o == this)
            return true;
        if (!(o instanceof SqlFileGroupSourceModel))
            return false;
        SqlFileGroupSourceModel other = (SqlFileGroupSourceModel) o;
        if (!other.canEqual(this))
            return false;
        Object thisSource = getSource();
        Object otherSource = other.getSource();
        if (thisSource == null ? otherSource != null : !thisSource.equals(otherSource)) {
            return false;
        }
        return true;
    }

    protected boolean canEqual(Object other) {
        return other instanceof SqlFileGroupSourceModel;
    }

    @Override
    public int hashCode() {
        int PRIME = 59;
        int result = 1;
        Object source = getSource();
        result = result * PRIME + (source == null ? 43 : source.hashCode());
        return result * PRIME + 79;
    }

}
